package com.lollipop.common;

import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;

import java.util.List;

@Getter
@Setter
@AllArgsConstructor
@ToString
public class Pager<T> {

    int total = 0;
    List<T> data;

    public static <T> Pager<T> getResult(int total, List<T> data) {
        return new Pager<T>(total, data);
    }

}
